#ifndef WIDGET_H
#define WIDGET_H

#include <QWidget>
#include <QUdpSocket>
#include <QHostInfo>
#include <QNetworkInterface>
#include <QDebug>
#include <QMessageBox>
#include "getImage.h"
#include "receiveImage.h"

#include "networkassistant.h"

class GetImage;
class ReceiveImage;
class NetworkAssistant;

QT_BEGIN_NAMESPACE
namespace Ui { class Widget; }
QT_END_NAMESPACE

class Widget : public QWidget
{
    Q_OBJECT

public:
    Widget(QWidget *parent = nullptr);
    ~Widget();

private:
    GetImage image_cam;
    ReceiveImage receive_image;
    NetworkAssistant *network_assistant;

    Ui::Widget *ui;
private slots:
    void startNetworkAssistant();

    void showImage(const QImage &image);

    void showReceiveCamera(const QImage &image);

    void sendImage();

    void receiveImage();
};
#endif // WIDGET_H
